#include <stdio.h>
#include <iostream>
#include <stdlib.h>
#include <ctime>
#include <cstdlib>
#include <fstream>

using namespace std;

///g++ testing.cpp -o testing; g++ generador.cpp -o generador;./generador ;chmod 777 generadores.txt; ./generadores.txt 1

///cout << "./main n m0 ml mp k_ini l_ini p_ini" << endl;
///cout << "k_ini l_ini p_ini son el coeficiente, cantidad de autos livianos, y cantidad de autos pesados del primer piso" << endl;
int main(int argc, char* argv[])
{
    remove("./generadores.txt");
    srand((unsigned)time(0));
    int random_integer = rand();
    ofstream pepa;
    pepa.open("./generadores.txt",ios::app);

        int n,m0,ml,mp,k,cantl,cantp;

for( int i =0 ; i<20; i++)
    {
        m0 = rand()%100000;
        ml = rand()%1000;
        do
        {
            mp = rand()%5000;
        }
        while(mp<=ml);

            n = rand()%20;

        do
        {
            k = rand();
        }
        while(!(100000 < k && k<= 2000000));

        cantl = rand()%1000;
        cantp = rand()%1000;

        pepa<<"./testing "<< n <<" "<< m0 <<" "<< ml <<" "<< mp <<" "<< k <<" "<< cantl <<" "<< cantp <<" "<<"CantPesados"<<i<<endl;

    }
    return 0;
}
